Skip to content

Recommend settings file pattern for Claude Code subscription OAuth gateway config - #5818

Open
langsmith-fleet[bot] wants to merge 4 commits into
mainfrom
docs/llm-gateway-coding-agents-settings-file-pattern
Open

Recommend settings file pattern for Claude Code subscription OAuth gateway config#5818
langsmith-fleet[bot] wants to merge 4 commits into
mainfrom
docs/llm-gateway-coding-agents-settings-file-pattern

Conversation

@langsmith-fleet

Copy link
Copy Markdown
Contributor

Summary

  • In the "Use Claude subscription OAuth" section of the Claude Code CLI docs, adds a --settings file approach as the recommended way to configure the LLM Gateway
  • Using ~/.claude/langsmith.settings.json with claude --settings keeps ANTHROPIC_CUSTOM_HEADERS (which embeds the LangSmith API key) out of the shell environment, history, and dotfiles
  • Includes a chmod 600 reminder to restrict file permissions
  • The export env var approach is retained as a fallback option

Links

Verification

Not run; docs-only copy change.

Reviewers

Requested review from: Kathryn May (@katmayb), Florence Morris (@fjmorris)


Supersedes #5817 (which modified the wrong page).

Add a --settings file approach as the recommended way to configure the
LLM Gateway for Claude Code subscription OAuth users. Using a named
settings file keeps ANTHROPIC_CUSTOM_HEADERS (which embeds the
LangSmith API key) out of the shell environment, shell history, and
dotfiles. The export-based approach is retained as a fallback.
@github-actions github-actions Bot added the langsmith For docs changes to LangSmith label Sep 2, 2026
@github-actions github-actions Bot added the external User is not a member of langchain-ai label Sep 2, 2026
Docs Bot added 2 commits September 2, 2026 00:31
… Claude file permissions

- Add recommended/fallback pattern to 'Use Anthropic models only' and
  'Route model tiers across providers' sub-sections, matching the
  structure already added to the OAuth section
- Use chmod matching ~/.claude/settings.json permissions (via stat -f)
  instead of a hardcoded permission mode, across all three examples
- Update introductory sentence in workspace provider secret section to
  reference --settings rather than ~/.claude/settings.json directly
@jacoblee93
Jacob Lee (jacoblee93) marked this pull request as ready for review September 2, 2026 00:36
@github-actions

github-actions Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Mintlify preview branch generated: preview-docsll-1788309528-e7d1898

Site preview: https://langchain-5e9cc07a-preview-docsll-1788309528-e7d1898.mintlify.site

Important

Preview links may take a few minutes to start working while the deployment finishes.

Changed documentation pages (preview deep links):

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

external User is not a member of langchain-ai langsmith For docs changes to LangSmith

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant